<!DOCTYPE html>
<html lang="en" xmlns:th="http://www.thymeleaf.org">
<head th:fragment="head(title)">
    <meta charset="UTF-8">
    <title th:replace="${title}">Title</title>
    <script src="  https://cdn.bootcdn.net/ajax/libs/jquery/3.5.1/jquery.js " type="text/javascript" charset="utf-8"></script>
    <script src="https://cdn.jsdelivr.net/semantic-ui/2.2.4/semantic.min.js"></script>
    <link rel="stylesheet" href="https://cdn.jsdelivr.net/semantic-ui/2.2.4/semantic.min.css">
    <link rel="stylesheet" href="../static/css/mi1.css" th:href="@{/css/mi1.css}">
    <link rel="stylesheet" href="../static/css/typo.css" th:href="@{/css/typo.css}" />
    <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/animate.css/4.1.0/animate.compat.css">
    <link rel="stylesheet" href="../static/lib/prism/prism.css" th:href="@{/lib/prism/prism.css}">
<!--    <link rel="stylesheet" href="https://cdn.bootcdn.net/ajax/libs/tocbot/4.12.0/tocbot.css ">-->
    <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/tocbot/4.5.0/tocbot.css">
</head>
<body>

<nav th:fragment="menu(n)" class="ui inverted attached segment m-padded-tb-mini" >
    <div class="ui container">
        <div class="ui menu inverted secondary stackable">
            <h2 class="ui teal header item"><i class="home icon"></i>脏丽丽</h2>
            <a href="#" th:href="@{/}" class="m-item m-mobile-hide item" th:classappend="${n==1}?'active'"><i class="mini idea icon"></i>首页</a>
            <a href="#" th:href="@{/types/-1}" class="m-item m-mobile-hide item"  th:classappend="${n==2}?'active'"><i class="mini idea icon"></i>分类</a>
            <a href="#" th:href="@{/tags/-1}" class="m-item m-mobile-hide item"  th:classappend="${n==3}?'active'"><i class="mini tags icon"></i>标签</a>
            <a href="#" th:href="@{/archives}" class="m-item m-mobile-hide item"  th:classappend="${n==4}?'active'"><i class="mini clone icon"></i>归档</a>
            <a href="#" th:href="@{/about}" class="m-item m-mobile-hide item"  th:classappend="${n==5}?'active'"><i class="mini info icon"></i>关于我</a>
            <div class="right item m-mobile-hide">
                <form action="#" method="post" name="search" th:action="@{/search}" target="_blank">
                    <div class = "ui icon transparent inverted input">
                        <input type="text" name="query" placeholder="搜我吧"  th:value="${query}" />
                        <i onclick="document.forms['search'].submit()" class="search link icon"></i>
                    </div>
                </form>

            </div>
        </div>
    </div>
    <a href="#" class="ui black menu toggle icon button m-right-top m-mobile-show">
        <i class="sidebar icon"></i>
    </a>
</nav>

<!--底部-->
<footer th:fragment="footer" class="ui inverted vertical segment m-padded-tb-massive">
    <div class="ui center aligned  container">
        <div class="ui inverted divided grid stackable">
            <div class="three wide column">
                <div class="inverted ui link list">
                    <div class="item">
                        <img th:src="@{/img/小俊男.jpg}" src="../static/img/小俊男.jpg" style="width:110px " alt="" class="ui rounded image">

                    </div>
                </div>
            </div>
            <div class="three wide column">
                <h4 class="ui inverted header m-text-thin m-text-spaced">最新博客</h4>


                    <div id="newblog-container">
                        <div class="ui inverted link list" th:fragment="newblogList">
                      <a href="#"  th:each="blog : ${newblogs}" th:href="@{/blog/{id}(id=${blog.id})}" class="item m-text-thin"
                        th:text="${blog.title}" >用户登录</a>
                </div>
                </div>

            </div>
            <div class="three wide column">
                <div class="ui inverted link list">
                    <h4 class="ui inverted header m-text-thin m-text-spaced" >联系我</h4>
                    <a href="#" class="item">WeChat：747296681</a>
                    <a href="#" class="item">Email：s747296681@vip.qq.com</a>
                </div>

            </div>
            <div class="seven wide column">
                <div class="ui inverted link list">
                    <h4 class="ui inverted header m-text-thin m-text-spaced">最新博客</h4>
                    <p  class="m-text-thin m-text-spaced m-opacity-mini">这是脏丽丽的个人博客！里面有好多好玩的东西哟！</p>
                </div>

            </div>

        </div>
        <div class="ui inverted section divider"></div>
        <p class="m-text-thin m-text-spaced m-opacity-tiny">copy right 2019-2020</p>
    </div>

</footer>
<script>
    $('#newblog-container').load(/*[[@{/footer/newblog}]]*/"/footer/newblog");
</script>



<th:block th:fragment="script">
    <script th:src="@{/lib/prism/prism.js}"></script>
    <script  th:src="@{/lib/qrcode/qrcode.min.js}"></script>
    <script src="https://cdnjs.cloudflare.com/ajax/libs/tocbot/4.5.0/tocbot.min.js"></script>
    <script src=" https://cdn.bootcdn.net/ajax/libs/jquery-scrollTo/2.1.2/jquery.scrollTo.min.js "></script>
</th:block>

</body>
</html>